package com.lce.beans;

import com.fasterxml.jackson.annotation.JsonFormat;
import jdk.internal.dynalink.linker.LinkerServices;

import java.util.Date;
import java.util.List;

public class User {
    private int uid;
    private int rid;
    private int did;
    private String ucard;
    private String uname;
    private String password;
    private String sex;
    private int age;
    private String birthday;
    private String email;
    private String phone;
    private String image;
    private String address;
    private Role role;
    private Dept dept;
    private TimeTable timeTable;
    private List<Attendance> attendances;

    public User() {
    }

    public User(int uid, String uname, String password, String sex, int age, String birthday, String email, String phone, String image, String address) {
        this.uid = uid;
        this.uname = uname;
        this.password = password;
        this.sex = sex;
        this.age = age;
        this.birthday = birthday;
        this.email = email;
        this.phone = phone;
        this.image = image;
        this.address = address;
    }

    public User(int uid, int rid, int did, String ucard, String uname, String password, String sex, int age, String birthday, String email, String phone, String image, String address, Role role, Dept dept, TimeTable timeTable, List<Attendance> attendances) {
        this.uid = uid;
        this.rid = rid;
        this.did = did;
        this.ucard = ucard;
        this.uname = uname;
        this.password = password;
        this.sex = sex;
        this.age = age;
        this.birthday = birthday;
        this.email = email;
        this.phone = phone;
        this.image = image;
        this.address = address;
        this.role = role;
        this.dept = dept;
        this.timeTable = timeTable;
        this.attendances = attendances;
    }

    public Role getRole() {
        return role;
    }

    public List<Attendance> getAttendances() {
        return attendances;
    }

    public void setAttendances(List<Attendance> attendances) {
        this.attendances = attendances;
    }

    /**
     * 获取
     *
     * @return uid
     */
    public int getUid() {
        return uid;
    }

    /**
     * 设置
     *
     * @param uid
     */
    public void setUid(int uid) {
        this.uid = uid;
    }

    /**
     * 获取
     *
     * @return rid
     */
    public int getRid() {
        return rid;
    }

    /**
     * 设置
     *
     * @param rid
     */
    public void setRid(int rid) {
        this.rid = rid;
    }

    /**
     * 获取
     *
     * @return did
     */
    public int getDid() {
        return did;
    }

    /**
     * 设置
     *
     * @param did
     */
    public void setDid(int did) {
        this.did = did;
    }

    /**
     * 获取
     *
     * @return ucard
     */
    public String getUcard() {
        return ucard;
    }

    /**
     * 设置
     *
     * @param ucard
     */
    public void setUcard(String ucard) {
        this.ucard = ucard;
    }

    /**
     * 获取
     *
     * @return uname
     */
    public String getUname() {
        return uname;
    }

    /**
     * 设置
     *
     * @param uname
     */
    public void setUname(String uname) {
        this.uname = uname;
    }

    /**
     * 获取
     *
     * @return password
     */
    public String getPassword() {
        return password;
    }

    /**
     * 设置
     *
     * @param password
     */
    public void setPassword(String password) {
        this.password = password;
    }

    /**
     * 获取
     *
     * @return sex
     */
    public String getSex() {
        return sex;
    }

    /**
     * 设置
     *
     * @param sex
     */
    public void setSex(String sex) {
        this.sex = sex;
    }

    /**
     * 获取
     *
     * @return age
     */
    public int getAge() {
        return age;
    }

    /**
     * 设置
     *
     * @param age
     */
    public void setAge(int age) {
        this.age = age;
    }

    /**
     * 获取
     *
     * @return birthday
     */
    public String getBirthday() {
        return birthday;
    }

    /**
     * 设置
     *
     * @param birthday
     */
    public void setBirthday(String birthday) {
        this.birthday = birthday;
    }

    /**
     * 获取
     *
     * @return email
     */
    public String getEmail() {
        return email;
    }

    /**
     * 设置
     *
     * @param email
     */
    public void setEmail(String email) {
        this.email = email;
    }

    /**
     * 获取
     *
     * @return phone
     */
    public String getPhone() {
        return phone;
    }

    /**
     * 设置
     *
     * @param phone
     */
    public void setPhone(String phone) {
        this.phone = phone;
    }

    /**
     * 获取
     *
     * @return image
     */
    public String getImage() {
        return image;
    }

    /**
     * 设置
     *
     * @param image
     */
    public void setImage(String image) {
        this.image = image;
    }

    /**
     * 获取
     *
     * @return address
     */
    public String getAddress() {
        return address;
    }

    /**
     * 设置
     *
     * @param address
     */
    public void setAddress(String address) {
        this.address = address;
    }

    /**
     * 设置
     *
     * @param role
     */
    public void setRole(Role role) {
        this.role = role;
    }

    /**
     * 获取
     *
     * @return dept
     */
    public Dept getDept() {
        return dept;
    }

    /**
     * 设置
     *
     * @param dept
     */
    public void setDept(Dept dept) {
        this.dept = dept;
    }

    /**
     * 获取
     *
     * @return timeTable
     */
    public TimeTable getTimeTable() {
        return timeTable;
    }

    /**
     * 设置
     *
     * @param timeTable
     */
    public void setTimeTable(TimeTable timeTable) {
        this.timeTable = timeTable;
    }

    public String toString() {
        return "User{uid = " + uid + ", rid = " + rid + ", did = " + did + ", ucard = " + ucard + ", uname = " + uname + ", password = " + password + ", sex = " + sex + ", age = " + age + ", birthday = " + birthday + ", email = " + email + ", phone = " + phone + ", image = " + image + ", address = " + address + "}";
    }
}
